package xinxin.com.StatePattern;

import xinxin.com.StatePattern.Work.Work;

/**
 * @author ：史鑫鑫
 * @date ：Created in 2019/3/26 8:47
 */
public class StatePattern {
    static int Hour = 22;
    static boolean WorkFinished = false;

    public static void main(String[] args) {
        Work work = new Work();
        work.setHour(9);
        work.WriteProgram();
        work.setHour(12);
        work.WriteProgram();
        work.setHour(20);
        work.WriteProgram();
    }
}
